home *** CD-ROM | disk | FTP | other *** search
- { iaounit.pas -- Demonstrate unit entry and exit code }
-
- unit IAOUnit;
-
- interface
-
- { Insert any public declarations here }
-
- implementation
-
- uses WinTypes, WinProcs;
-
- const
-
- caption = 'InAndOut Unit'; { Caption for message box }
-
- var
-
- Chain: Pointer;
-
- {- Exit procedure. Runs at end of application. }
- procedure UnitExitProc; far;
- begin
- MessageBox(0, 'Exiting unit', caption,
- mb_TaskModal or mb_Ok);
- ExitProc := Chain
- end;
-
- begin
- MessageBox(0, 'Entering unit', caption,
- mb_TaskModal or mb_Ok);
- Chain := ExitProc;
- ExitProc := @UnitExitProc
- end.
-
-
- {--------------------------------------------------------------
- Copyright (c) 1991 by Tom Swan. All rights reserved.
- Revision 1.00 Date: 5/25/1991
- ---------------------------------------------------------------}
-